﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using PaymentHelper.Core.RelatedObject;
using System.ComponentModel.DataAnnotations;
using System.Web.Mvc;

namespace PaymentHelper.Methods.PaypalDirect.Models
{
    public class PaymentModel
    {
        [Required(ErrorMessage = "CreditCard Number is required")]
        public string CreditCardNumber { get; set; }

        [Required(ErrorMessage = "Card Holder name is required")]
        public string CardOwnerName { get; set; }

        [Required(ErrorMessage = "CreditCard type is required")]
        public string CreditCardType { get; set; }

        [Range(1, 12, ErrorMessage = "Month must be between 1 and 12")]
        [Required(ErrorMessage = "Exp month is required")]
        public int ExpMonth { get; set; }

        [Range(2012,99999, ErrorMessage="Year is invalid")]
        [Required(ErrorMessage = "Exp year is required")]
        public int ExpYear { get; set; }

        [Required(ErrorMessage = "CVV2 is required")]
        public string CreditCardCVV2 { get; set; }

        public IEnumerable<SelectListItem> ListCard { get; set; }
    }
}
